package com.mjduan.myBank.util.crypto;

import org.apache.shiro.crypto.hash.Md5Hash;

/**
 * Shiro加密
 * 
 * @author Duan
 *
 */
public class CryptographyUtil {
	
	private static final String salt="耶律齐元";
	/**
	 * Md5加密
	 * @param str
	 * @param salt
	 * @return
	 */
	public static String md5(String str){
		return new Md5Hash(str,salt).toString();
	}
	
	/*public static void main(String[] args) {
		//String password="123456";
		
		//System.out.println("加密:"+CryptographyUtil.md5(password, "java1234").length());
	}*/
}
